<?php
global $_GPC, $_W;

$GLOBALS['frames'] = $this->getMainMenu();
$storetype=pdo_getall('cjdc_storetype',array('uniacid'=>$_W['uniacid']),array(),'','num asc');
$sql="SELECT * FROM ".tablename('cjdc_user_agent')."  where id=:id ";
$item=pdo_fetch($sql,array(':id'=>$_GPC['id']));

if(checksubmit('submit')){   
	$data['mangername']=$_GPC['name'];    
	$data['city_name'] = $_GPC['address']; 
	$data['username']=$_GPC['link_name'];
	$data['mobile']=$_GPC['link_tel'];
	$data['state']=$_GPC['state'];
	$data['createtime']=date("Y-m-d H:i:s",time());
	
	$rst=pdo_update('cjdc_user_agent',$data,array('id'=>$item['id']));
	if($rst){

	     message('编辑成功！', $this->createWebUrl('csdlcheck'), 'success');
	}else{
	     message('编辑失败！','','error');
	}

}

include $this->template('web/csdlcheckinfo');